home *** CD-ROM | disk | FTP | other *** search
/ 5 Star Games: DOS Edition 2 / 5 Star Games - DOS Edition (1995)(Ready to Run).iso / dbc / db_file.h < prev    next >
Text File  |  1992-02-28  |  2KB  |  48 lines

  1. /****************************************************************************/
  2. /*                 HEADER FILE FOR DATABOSS MODULE: DB_FILE.C               */
  3. /****************************************************************************/
  4.  
  5. /*********************************  CONSTANTS *******************************/
  6.  
  7. #define A_RDONLY  0x01
  8. #define A_HIDDEN  0x02
  9. #define A_SYSTEM  0x04
  10. #define A_LABEL   0x08
  11. #define A_DIREC   0x10
  12. #define A_ARCH    0x20
  13. #define A_ANYFILE 0x3F
  14.  
  15. /***********************************  TYPES  ********************************/
  16.  
  17. typedef uchar pathstr[80];
  18. typedef uchar drivestr[3];
  19. typedef uchar dirstr[68];
  20. typedef uchar namestr[9];
  21. typedef uchar extstr[5];
  22. typedef uchar filenamestr[13];
  23. typedef struct {
  24.     uchar reserved[21];
  25.     uchar attrib;
  26.     word time;
  27.     word date;
  28.     long size;
  29.     uchar name[13];
  30. } findrec;
  31.  
  32. /*******************************  PROTOTYPES  *******************************/
  33.  
  34. strptr getenvstr(strptr sout, string envar);
  35. strptr fsearch(pathstr fnout, pathstr fnin, string path);
  36. void fsplit(pathstr path, dirstr dir, namestr name, extstr ext);
  37. strptr fexpand(pathstr sout, pathstr path);
  38. bool getcurrentdir(pathstr sout, byte drive);
  39. bool changedrive(uchar drive);
  40. bool changedir(pathstr path);
  41. bool db_eof(FILE *f);
  42.     /*    returns true if at end of file
  43.             only works for files that have opened in binary mode */
  44. bool db_findfirst(pathstr path, findrec *frec, int attr);
  45. bool db_findnext(findrec *frec);
  46.  
  47. /***************************** END OF DB_FILE.H *****************************/
  48.